This function converts a date of data type DTL into a character string of data type STRING in international format (YYYY MM DD…).
| LGF_DTLtoString_ISO (FC) | ||||||||
|---|---|---|---|---|---|---|---|---|
| DTL | date | Ret_Val | String | |||||
| Char | separator | |||||||
| Identifier | Data type | Description |
|---|---|---|
| date | DTL | Date to convert as DTL tag |
| separator | Char | Separator between the components of the output date. |
| Identifier | Data type | Description |
|---|---|---|
| Ret_Val | String | Output string in accordance with the ISO 8601 format. Example: `2019-01-22 14:06:51.524621000`. |
The block reads a date of data type DTL and converts the individual components of the date (year, month, day, hour…) into a character string and outputs it in international format. The separator between the components of the date is variable.
####### International format (ISO 8601):

####### Separator:
At the input parameter separatorDate, you specify the separator between the components of the calendar date.
####### Example:
/ - outString = 2016/03/16…- - outString = 2016-03-16…| Version & Date | Change description | |
|---|---|---|
| 01.00.00 | Siemens Industry Online Support | |
| 15.06.2016 | First released version | |
| 01.00.01 | Siemens Industry Online Support | |
| 02.01.2017 | Upgrade: TIA Portal V14 Update 1 | |
| 01.00.02 | Siemens Industry Online Support | |
| 17.08.2018 | Upgrade: TIA V15 Update 2 | |
| 01.00.03 | Siemens Industry Online Support | |
| 23.11.2018 | Upgrade: TIA V15.1 | |
| 01.00.04 | Simatic Systems Support | |
| 17.07.2019 | Bugfix - nanosecond precision and '0' filling | |
| 01.00.05 | Simatic Systems Support | |
| 18.07.2019 | Renamed from "LGF_DTLtoString" to "LGF_DTLtoString_ISO" Split into two blocks, removed "format" input | |
| 03.00.00 | Simatic Systems Support | |
| 23.04.2020 | Set version to V3.0.0 Harmonize the version of the whole library | |
| 03.00.01 | Simatic Systems Support | |
| 23.02.2021 | Insert documentation | |